﻿<%namespace YouHP.Model%>
<%namespace YouHP.Utility%>
<%template _header%>

<script language="javascript" src="/support/editor/script_common.js"></script>

<script language="javascript" src="/support/editor/editor_function.js"></script>

<div class="layout-cols2">
    <%csharp%>if( IsPost){
    <%/csharp%>
    <%template _MsgBox%>
    <%csharp%>
    } else {
    <%/csharp%>
    <div class="box">
        <div class="caption">
            发表话题
        </div>
        <div class="content">
            <br />
            <form id="topicform" name="topicform" method="post" action="" enctype="multipart/form-data">
            <input type="hidden" name="gid" value="{GroupData.Id}">
            <table class="editboxstyle">
                <tbody>
                    <tr>
                        <td>
                            标题：
                        </td>
                        <td>
                            <input type="text" name="ttitle" size="60" class="inputstyle" />
                            &nbsp;&nbsp;<span>标题长度必须在{Config.TitleMinSize}-{Config.TitleMaxSize}之间</span>
                        </td>
                    </tr>
                    <tr valign="top">
                        <td>
                            内容：
                        </td>
                        <td>
                            <textarea id="uchome-ttHtmlEditor" name="tbody" cols="90" rows="15" style="display: none"></textarea>
                            <iframe src="/support/editor/editor.htm" name="uchome-ifrHtmlEditor" id="uchome-ifrHtmlEditor"
                                scrolling="no" border="0" frameborder="0" style="width: 600px; border: 1px solid #C5C5C5;"
                                height="300"></iframe>
                            <p>
                                内容长度必须在{Config.TopicMinSize}-{Config.TopicMaxSize}之间</p>
                        </td>
                    </tr>
                    <tr>
                        <td>
                            附件：
                        </td>
                        <td>
                            <input name="file" id="file" type="file" size="40" class="colorblue" onfocus="this.className='colorfocus';"
                                onblur="this.className='colorblue';" />
                            <span>类型限定（RAR、ZIP、TXT、JPG、PNG、GIF）文件最大为1M</span>
                        </td>
                    </tr>
                    <tr>
                        <td>
                        </td>
                        <td align="right">
                            <a href="#" onclick="javascript:edit_save();CheckForm();" class="yellowbutton">提交</a>
                        </td>
                    </tr>
                </tbody>
            </table>
            </form>

            <script type="text/javascript">
	                function CheckForm()
	                {
	                    document.getElementById('topicform').submit();
	                }
            </script>

            <br />
        </div>
    </div>
    <%csharp%>
    }
    <%/csharp%>
</div>
<%template _footer%>